package cn.com.cennavi.bean;

import java.io.Serializable;

/**
 * 
 * @Description od模块热点区域子模块输出标准
 * @author buf
 * @date 2017年2月17日 下午4:01:28
 */
public class OD_HotSpot_OutDataBean implements Serializable {
	/**
	 * 年月日yyyyMMdd
	 */
	public int date;  
	/**
	 * 星期特征日，java规则
	 */
	public int weekday;
	/**
	 * OD统计时间粒度，单位分钟，默认60
	 */
	public int timeGranularity;
	/**
	 * 时段标识，按照time_granularity将一天分成多个时段，time_index标识统计的时段，从0开始编号，0表示00:00-xx:xx
	 */
	public int timeIndex;  
	/**
	 * 最小小网格ID，暂定为8位（6位二次网格+1位5km*5km+1位2.5*2.5km）
	 */
	public int minGridId;
	/**
	 * 所属最优小网格/路段ID，最优指通过分析得到的能最好反应区域特点的范围，或用户上传网格划分。默认为最小网格
	 */
	public int bestGridId;
	/**
	 * 所属区县
	 */
	public int county;
	/**
	 * 所属城市
	 */
	public int city;
	/**
	 * 所属省份
	 */
	public int province;
	/**
	 * 从最小空间粒度出发的od数
	 */
	public int oNum;
	/**
	 * 从最小空间粒度到达的od数
	 */
	public int dNum;

	public String toDataString() {
		StringBuffer sb = new StringBuffer();
		sb.append(date);
		sb.append(",");
		sb.append(weekday);
		sb.append(",");
		sb.append(timeGranularity);
		sb.append(",");
		sb.append(timeIndex);
		sb.append(",");
		sb.append(minGridId);
		sb.append(",");
		sb.append(bestGridId);
		sb.append(",");
		sb.append(county);
		sb.append(",");
		sb.append(city);
		sb.append(",");
		sb.append(province);
		return sb.toString();
	}

	public String toString() {
		StringBuffer sb = new StringBuffer();
		sb.append(date);
		sb.append(",");
		sb.append(weekday);
		sb.append(",");
		sb.append(timeGranularity);
		sb.append(",");
		sb.append(timeIndex);
		sb.append(",");
		sb.append(minGridId);
		sb.append(",");
		sb.append(bestGridId);
		sb.append(",");
		sb.append(county);
		sb.append(",");
		sb.append(city);
		sb.append(",");
		sb.append(province);
		sb.append(",");
		sb.append(oNum);
		sb.append(",");
		sb.append(dNum);
		return sb.toString();
	}
}
